package LeetCode.month02.day33;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Scanner;



public class Code {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        for (int i = 0; i < n; i++) {
            int a = sc.nextInt();
            int b = sc.nextInt();
            getRes(a,b);
        }
    }

    public static void getRes(int n,int k){
        String[] s = {"blue","red"};
        boolean flag = n % 2 == 1;
        if(n==1) {
            System.out.println("red");
            return;
        }
        else{
            int len =(int) Math.pow(2,n-1);

            while(len>2){
                k = k>=len/2?len-k-1:k;
                len/=2;
            }
        }
        if(flag) {
            System.out.println(s[(k+1)%2]);
        }
        else {
            System.out.println(s[k]);
        }
    }
}

/*
r
br
rbbr
brrbrbbr
rbbrbrrbrbbrbrrb

 */
